home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 26 / Cream of the Crop 26.iso / program / qlib205.zip / QLIB.ZIP / SRC / MATH / MATH_WC.ASM < prev   
Assembly Source File  |  1997-03-22  |  520b  |  33 lines

  1. ; Math Library to be used in C programs (WATCOM)
  2.  
  3. ; results are returned in CPU regs
  4.  
  5. include qlib.inc
  6. include math.inc
  7. include string.inc
  8. include errno.inc
  9.  
  10. .data
  11. _WC_ equ 1
  12. _math_typ db 1
  13. include math_com.asm
  14. include ftoa.asm
  15.  
  16. .code
  17. ;this was stripped out of WATCOM Libs
  18. _CHP proc  ;chop!!!
  19.   push    eax
  20.   fstcw   wptr[esp]
  21.   fwait    
  22.   push    dptr[esp]
  23.   mov     byte ptr [esp+1],1fH
  24.   fldcw   wptr[esp]
  25.   frndint 
  26.   fldcw   wptr[esp+4]
  27.   fwait    
  28.   add esp,8
  29.   ret
  30. _CHP endp
  31.  
  32. end
  33.